import request from '@/utils/request'

//查询所有数据
export function listAll(data){
  return request({
    url:'/api/xmwh/list',
    params:data,
    method:'GET'
  })
}
//删除一条数据
export function deleteone(data){
  return request({
    url:'/api/xmwh/'+data.id,
    method:'Delete',
    data
  })
}
//添加一条数据
export function addone(data){
  return request({
    url:'/api/xmwh/add',
    method:'POST',
    data
  })
}

//修改一条数据
export function updateone(data){
  return request({
    url:'/api/xmwh/update',
    method:'POST',
    data
  })
}

//查询所有数据
export function rw3list(data){
  return request({
    url:'/api/gcjm/list',
    params:data,
    method:'GET'
  })
}
//删除一条数据
export function rw3delete(data){
  return request({
    url:'/api/gcjm/'+data.id,
    method:'Delete',
    data
  })
}

//添加一条数据
export function rw3add(data){
  return request({
    url:'/api/gcjm/add',
    method:'POST',
    data
  })
}
//查询所有数据
export function rw4list(data){
  return request({
    url:'/api/mes/list',
    params:data,
    method:'GET'
  })
}
//删除一条数据
export function rw4delete(data){
  return request({
    url:'/api/mes/'+data.id,
    method:'Delete',
    data
  })
}
//添加一条数据
export function rw4add(data){
  return request({
    url:'/api/mes/add',
    method:'POST',
    data
  })
}
//修改一条数据
export function rw4update(data){
  return request({
    url:'/api/mes/edit',
    method:'POST',
    data
  })
}
//能效预警删除
export function nxyjsc(data) {
	return request({
		url: '/api/nxyj/' + data.id,
		method: 'DELETE'
	})
}
//能效预警新增
export function nxyjadd(data) {
	return request({
		url: '/api/nxyj/add',
		method: 'POST',
		data
	})
}
//能效预警修改
export function nxyjxg(data) {
	return request({
		url: '/api/nxyj/update',
		method: 'POST',
		data
	})
}
// 数据查询
export function nxyjlist(data) {
	return request({
		url: '/api/nxyj/list',
		method: 'GET',
		params: data
	})
}
// 任务5任务详情
export function ptdtlist(data){
	return request({
		url:'/api/ptdt/list',
		method:'GET',
		params:data
	})
}
// 任务6公告详情
export function ggxq(data){
	return request({
		url:'/api/xxgg/list2',
		method:'GET',
		params:data
	})
}
